const mongoose = require('mongoose')

const schema = new mongoose.Schema({
  userId: {
    type: mongoose.SchemaTypes.ObjectId,
    ref: 'User'
  },
  product: {
    type: mongoose.SchemaTypes.ObjectId,
    ref: 'ServiceProduct'
  },
  count: {
      type: Number,
      default: 1
  }
})

module.exports = mongoose.model('ShoppingCart', schema)